The File note type can be used to attach various external files such as images, videos or PDF documents.

Uploading a file

Since these files come from an external source, it is not possible to create a File note type directly:

Supported file types

PDFs

PDFs can be browsed directly from Trilium.

Interaction:

Images

Interaction:

Videos

Video files can be added in as well. The file is streamed directly, so when accessing the note from a server it doesn't have to download the entire video to start playing it.

Audio

Adding a supported audio file will reveal a basic audio player that can be used to play it.

Interactions:

Text files

Files that are identified as containing text will show a preview of their content. One common use case for this type of file is to embed text files whose content is not necessarily of interest to the user, such as third-party libraries or generated content, that can then be downloaded if needed.

Note that generally text files will be imported as either Text or  Code notes. To bypass this behavior and create a File note type, use the Import into note feature and uncheck Import HTML, Markdown and TXT as text notes, as well as Import recognized code files as code notes

Since one of the use cases for having files instead of notes is to display large files, the content preview is limited to a relatively small amount of characters. To view the full file, consider opening it in an external application.

Unknown file types

If the file could not be identified as any of the supported file types from above, it will be treated as an unknown file. In this case, all the default interactions will be available such as downloading or opening the file externally, but there will be no preview of the content.

Interaction

Relation with other notes